package com.jingdianjichi.subject.converter;

import com.jingdianjichi.subject.eneity.EmployeeBO;
import com.jingdianjichi.subject.infra.basic.entity.Employee;

import java.util.List;

import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

@Mapper
public interface EmployeeConverter {
    EmployeeConverter INSTANCE = Mappers.getMapper(EmployeeConverter.class);
    //定义转换方法
    //使用中我想把employeeList对象转为employeeBOList对象，那么我就可以调用converterEmployeeToBo方法
    List<EmployeeBO> converterEmployeesToBos(List<Employee> employees);
    Employee converterBoToEmployee(EmployeeBO employeeBO);
    //使用中我想把employeeBOList对象转为employeeList对象，那么我就可以调用converterBoToEmployee方法
    List<Employee> converterBosToEmployees(List<EmployeeBO> employeeBOs);

    EmployeeBO converterEmployeeToBo(Employee employee);
}
